package com.cn.jinl.domain;

import com.cn.jinl.utils.CommonUtil;
import com.google.common.collect.ImmutableMap;
import com.google.common.collect.Lists;

import java.util.Date;
import java.util.List;
import java.util.Map;

public class ProcureStorageOut {
    private String id;

    private String storageOutType;

    private String storageOutCode;

    private String storageOutStatus;

    private String storageOutUser;

    private String storageOutTime;

    private String remark;

    private String takeUser;

    private String processName;
    private String materialName;

    private String status;

    private Date createTime;

    private Date updateTime;

    private int count;
    private int materialSize;

    private List<ProcureStorageOutHis>procureStorageOutHisList;

    public static final transient Map<String, String> STATUSMAP =
            ImmutableMap.of("0", "待出库", "1", "出库");

    public static final transient Map<String, String> STATUSTYPEMAP =
            ImmutableMap.of("1", "领用", "2", "报废");

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id == null ? null : id.trim();
    }

    public String getStorageOutTypeCn() {
        return STATUSTYPEMAP.get(getStorageOutType());
    }
    public String getStorageOutType() {
        return storageOutType;
    }

    public void setStorageOutType(String storageOutType) {
        this.storageOutType = storageOutType == null ? null : storageOutType.trim();
    }

    public String getStorageOutCode() {
        return storageOutCode;
    }

    public void setStorageOutCode(String storageOutCode) {
        this.storageOutCode = storageOutCode == null ? null : storageOutCode.trim();
    }

    public String getStorageOutStatusCn() {
        return STATUSMAP.get(getStorageOutStatus());
    }
    public String getStorageOutStatus() {
        return storageOutStatus;
    }

    public void setStorageOutStatus(String storageOutStatus) {
        this.storageOutStatus = storageOutStatus == null ? null : storageOutStatus.trim();
    }

    public String getStorageOutUser() {
        return storageOutUser;
    }

    public void setStorageOutUser(String storageOutUser) {
        this.storageOutUser = storageOutUser == null ? null : storageOutUser.trim();
    }

    public String getStorageOutTime() {
        return storageOutTime;
    }

    public void setStorageOutTime(String storageOutTime) {
        this.storageOutTime = storageOutTime == null ? null : storageOutTime.trim();
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark == null ? null : remark.trim();
    }

    public String getTakeUser() {
        return takeUser;
    }

    public void setTakeUser(String takeUser) {
        this.takeUser = takeUser == null ? null : takeUser.trim();
    }

    public String getProcessName() {
        return processName;
    }

    public void setProcessName(String processName) {
        this.processName = processName == null ? null : processName.trim();
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status == null ? null : status.trim();
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public Date getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
    }

    public int getCount() {
        return count;
    }

    public void setCount(int count) {
        this.count = count;
    }

    public List<ProcureStorageOutHis> getProcureStorageOutHisList() {
        return procureStorageOutHisList;
    }

    public void setProcureStorageOutHisList(List<ProcureStorageOutHis> procureStorageOutHisList) {
        this.procureStorageOutHisList = procureStorageOutHisList;
    }

    public int getMaterialSize() {
        return materialSize;
    }

    public void setMaterialSize(int materialSize) {
        this.materialSize = materialSize;
    }

    public String getMaterialName() {
        return materialName;
    }

    public void setMaterialName(String materialName) {
        this.materialName = materialName;
    }

    public String getCreateTimeFt(){
        String formatTime = CommonUtil.getStrTime(getCreateTime(),"yyyy-MM-dd HH:mm:ss");
        return formatTime;
    }
}